
<template>
  <div id="app">

    <!-- <home /> -->
    <keep-alive>
      <router-view>
        <!-- 一级路由出口 -->
      </router-view>
    </keep-alive>

  </div>
</template>

<script>
// import home from './views/Home/index.vue'
// 导入局部组件必须在scrip里面导入,在App里面导入
export default {
  // 组件名称
  name: 'App',
  // 组件参数接收来自父组件的数据
  props: {},
  // 接收局部注册的组件
  components: {
    // home
  },
  // 组件数据
  data () {
    return {}
  },
  created () {

  }

}
</script>
<style scoped lang="less">
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
}

#nav {
  padding: 30px;

  a {
    font-weight: bold;
    color: #2c3e50;

    &.router-link-exact-active {
      color: #42b983;
    }
  }
}
</style>
